package homework;

public class work05 {

	public static void main(String[] args) {
		fanzhuan("abcdefg", 2, 6);
	}
	
	public static void fanzhuan(String str,int s,int e){
		char[] ch = str.toCharArray();
		for(;s<e;s++,e--){
			char step = ch[s];
			ch[s]=ch[e];
			ch[e]=step;
		}
		String ss = new String(ch);
		System.out.println(ss);
	}
}
